<style type="text/css">
      body {
        padding-top: 40px;
        padding-bottom: 40px;
        background-color: #f5f5f5;
      }

      .form-signin {
        max-width: 300px;
        padding: 19px 29px 29px;
        margin: 0 auto 20px;
        background-color: #fff;
        border: 1px solid #e5e5e5;
        -webkit-border-radius: 5px;
           -moz-border-radius: 5px;
                border-radius: 5px;
        -webkit-box-shadow: 0 1px 2px rgba(0,0,0,.05);
           -moz-box-shadow: 0 1px 2px rgba(0,0,0,.05);
                box-shadow: 0 1px 2px rgba(0,0,0,.05);
      }
      .form-signin .form-signin-heading,
      .form-signin .checkbox {
        margin-bottom: 10px;
      }
      .form-signin input[type="text"],
      .form-signin input[type="password"] {
        font-size: 16px;
        height: auto;
        margin-bottom: 15px;
        padding: 7px 9px;
      }

    </style>
    
<?php
$this->pageTitle=Yii::app()->name . ' - Login';
?>

<div class="form">
	<?php $form=$this->beginWidget('bootstrap.widgets.TbActiveForm', array(
		'id'=>'login-form',
		'enableClientValidation'=>true,
		'htmlOptions'=>array('class'=>'form-signin'),
		'clientOptions'=>array(
			'validateOnSubmit'=>true,
		),
	)); ?>
			
		<h2 class="form-signin-heading"><?php echo Yii::t('label','Please sign in'); ?></h2>
		
		<?php if(Yii::app()->user->hasFlash('error')) 
			$this->widget('bootstrap.widgets.TbAlert', array(
			    'block'=>true, // display a larger alert block?
			    'fade'=>true, // use transitions?
			    'closeText'=>'×', // close link text - if set to false, no close link is displayed
			    'alerts'=>array( // configurations per alert type
				    'error'=>array('block'=>true, 'fade'=>true, 'closeText'=>'×'), // success, info, warning, error or danger
			    ),
			));
		?>
			
		<?php echo $form->textField($model,'username',array('class'=>'input-block-level', 'placeholder'=>Yii::t('label','Username/Email'))); ?>
		<?php echo $form->error($model,'username'); ?>
		
		<?php echo $form->passwordField($model,'password',array('class'=>'input-block-level','placeholder'=>Yii::t('label','Password'))); ?>
				
		<?php echo $form->checkBoxRow($model, 'rememberMe');?>
		
		<?php $this->widget('bootstrap.widgets.TbButton', array(
			'buttonType'=>'submit',
			'type'=>'primary',
			'size'=>'large',
			'label'=>Yii::t('label','Login')
		));?>
	</div>

	<?php $this->endWidget(); ?>
</div><!-- form -->
